package com.newland.boss1.zxy;

import org.apache.servicecomb.provider.pojo.RpcSchema;
import org.springframework.beans.factory.annotation.Value;

/**
 * @author : zhangxuyuan
 * @Project: servicecombexample
 * @Package com.newland.boss1.zxy
 * @date Date : 2021年02月20日 15:27
 */
//rpc方式调用，类似于dubbo
@RpcSchema(schemaId = "helloworldRpc",schemaInterface = HelloWorldEndPoint.class)
public class HelloWorldEndPointRpcImpl implements HelloWorldEndPoint {


    @Value("${server.port}")
    private String port;

    @Override
    public String sayHello(String name) {
        return "hello "+name+ " port "+port+ " rpc";
    }
}
